package com.example.client;

import com.example.common.Result;
import com.example.entity.Payment;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(name = "cloud-payment-service")
public interface PaymentClient {
    @PostMapping("/payment/create")
    Result<Payment> create(@RequestBody Payment payment);

    @GetMapping("/payment/get/{id}")
    Result<Payment> getPaymentById(@PathVariable("id") Long id);

    @GetMapping("/payment/port")
    String getPort();
} 